#pragma warning(disable: 4786)
#include <iostream>
#include <algorithm>
#include <string>
#include <list>

using namespace std;

int main()
{
	list<string> slst;
	cout<<"enter some string :"<<endl;
	string str;
	while(cin>>str)
		slst.push_back(str);
	cout<<"enter the string for find:"<<endl;
	string str_find;
	cin.clear();
	cin>>str_find;

	cout<<"find "<<count(slst.begin(),slst.end(),str_find)<<" string"<<endl;

	return 0;
}